package com.xcl.service.impl;

import com.xcl.mapper.ShuntMapper;
import com.xcl.pojo.Loading;
import com.xcl.service.ShuntServiceInter;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @ClassName ShuntServiceImpl
 * @Description 分流管理服务层实现类
 * @Author: xiaochaolei
 * @date 2021/7/2 10:27
 * @Version 1. 0
 */
@Service
public class ShuntServiceImpl implements ShuntServiceInter {
    @Autowired
    ShuntMapper shuntMapper;

    @Override
    public List<Loading> getLoadingBYStateOne() {
        return shuntMapper.getLoadingBYStateOne();
    }

    @Override
    public List<Loading> getLoadingBYStateOneLimit(int page, int limit) {
        return shuntMapper.getLoadingBYStateOneLimit((page-1)*limit,limit);
    }

    @Override
    public List<Loading> getLoadingBYStateTwo() {
        return shuntMapper.getLoadingBYStateTwo();
    }

    @Override
    public List<Loading> getLoadingBYStateTwoLimit(int page, int limit) {
        return shuntMapper.getLoadingBYStateTwoLimit((page-1)*limit,limit);
    }

    @Override
    public List<Loading> getLoadingBYStateThree() {
        return shuntMapper.getLoadingBYStateThree();
    }

    @Override
    public List<Loading> getLoadingBYStateThreeLimit(int page, int limit) {
        return shuntMapper.getLoadingBYStateThreeLimit((page-1)*limit,limit);
    }

    @Override
    public List<Loading> getLoadingByWhere(String waybill_id, String substationUnit, String modeTransport, String startDate, String endingDate, int page, int limit) {
        return shuntMapper.getLoadingByWhere(waybill_id,substationUnit,modeTransport,startDate,endingDate,(page-1)*limit,limit);
    }

    @Override
    public List<Loading> getLoadingByWhereTwo(String waybill_id, String modeTransport, int page, int limit) {
        return shuntMapper.getLoadingByWhereTwo(waybill_id,modeTransport,(page-1)*limit,limit);
    }

    @Override
    public int upteModificationOne(String[] strings) {
        return shuntMapper.upteModificationOne(strings);
    }

    @Override
    public int upteModificationTwo(String[] strings) {
        return shuntMapper.upteModificationTwo(strings);
    }

    @Override
    public int upteModificationThree(String[] strings) {
        return shuntMapper.upteModificationThree(strings);
    }


}
